/*
 * Copyright (c) 2022, tyustli
 *
 * SPDX-License-Identifier: Apache-2.0
 *
 * Change Logs:
 * Date           Author       Notes
 * 2022-02-08     tyustli      first implementation
 */

#include <stdio.h>
#include <math.h>

int main(int argc, char **argv)
{
    float a, b, c;

    float x1, x2;

    a = 1;
    b = 2;
    c = 1;

    x1 = (-b + sqrt(b * b - 4 * a * c)) / (2 * a);
    x2 = (-b - sqrt(b * b - 4 * a * c)) / (2 * a);

    printf("x1 is %f, x2 is %f\r\n", x1, x2);

    return 0;
}

/******************** end of file **********************/
